# Maintainer: opal hart <opal@wowana.me>
pkgname=py3-keyring
pkgver=23.5.0
pkgrel=0
pkgdesc="Access the system keyring service from Python"
url="https://github.com/jaraco/keyring"
arch="noarch"
license="GPL-3.0-only"
depends="
	py3-importlib-metadata
	py3-jeepney
	py3-secretstorage
	python3
	"
makedepends="py3-setuptools"
checkdepends="py3-pytest"
source="https://files.pythonhosted.org/packages/source/k/keyring/keyring-$pkgver.tar.gz"
builddir="$srcdir/keyring-$pkgver"

prepare() {
	default_prepare
	sed -e '/setuptools_scm/d' \
		-e "/^\[metadata\]/a version = $pkgver" \
		-i setup.cfg
}

build() {
	python3 setup.py build
}

check() {
	pytest
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
}

sha512sums="
5531c3d2287cbaa506ab10bf6b56e16b52a16e178ef322fea3b66c7626ea78698f863f19a699b9937b3052e47135e3dc603d28fac1ad9470d6df8bf5b8fa897e  keyring-23.5.0.tar.gz
"
